FROM python:3.8.10
#设置时区
RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone
RUN pip3 config  set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
RUN pip install -U pip
# 安装node环境
RUN curl -sL https://deb.nodesource.com/setup_14.x | bash -
RUN apt-get install -y nodejs
WORKDIR /code
COPY . .
RUN pip install -r requirements.txt
CMD ["python", "myweb/manage.py","runserver","0:8080"]